package model

import (
	"chitchat_http/util"
	"github.com/doujunyu/gogo/sql_aid"
)

const TableByChatGroup = "self_chat_group"


func ChatGroupToData(groupIds ...interface{})map[int64]map[string]interface{}{
	userSql, args := sql_aid.PgTable(TableByChatGroup).Field("id", "name", "introduce").WhereIn("id", groupIds...).ToSql()
	userdata, _ := sql_aid.DataToMap(PgSql.Query(userSql, args...))
	return util.ArrayColumnByInt64(&userdata, "id")
}

